﻿<%@ Page Title="" Language="C#" MasterPageFile="~/PBOfficeMaster.master" AutoEventWireup="true"
    CodeFile="LookNews.aspx.cs" Inherits="NewsManager_LookNews" %>

<%@ Register Assembly="AspNetPager" Namespace="Wuqi.Webdiyer" TagPrefix="webdiyer" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
    <style type="text/css">
        .branchtop
        {
            margin: 10px 50px;
            text-align: left;
            font-size: 12px;
        }
        .lbBranch
        {
            font-size: 14px;
            font-weight: bold;
            background-image: url('../imges/daohangbeijing1.jpg');
            background-repeat: no-repeat;
            text-align: center;
            margin: 0;
            color: White;
            padding-top: 7px;
            height: 22px;
            width: 110px;
        }
        .btnBranch
        {
            width: 50px;
            height: 25px;
            background-color: #ccffff;
            border: 1px solid #000099;
            color: #000099;
        }
       
        .txt
        {
            border: 1px solid #6699FF;
            color: Blue;
        }
        .mlength
        {
            display: block;
            width: 100px;
            overflow: hidden;
            white-space: nowrap;
            -o-text-overflow: ellipsis;
            text-decoration: none;
            text-overflow: ellipsis;
        }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
    <div style="width: 864px; font-size: 14px;">
        <div class="branchtop">
            <table>
                <tr>
                    <td>
                        当前位置
                    </td>
                    <td>
                        <div class="lbBranch">
                            查看新闻</div>
                    </td>
                </tr>
            </table>
        </div>
        <hr style="height: 1px; margin-left: 45px; color: Blue; width: 804px;" />
        <div style="text-align: left; margin: 7px 100px; width: 700px; height: 30px; border: 1px solid #ccc;
            padding-left: 8px;">
            新闻标题：<asp:TextBox ID="txtTitle" CssClass="txt" runat="server"></asp:TextBox>
            新闻类型：<asp:DropDownList ID="ddlNewsType" runat="server" DataTextField="TypeName" Height="20px"
                Width="116px">
            </asp:DropDownList>
            &nbsp;&nbsp;
            <asp:Button ID="btnCheck" CssClass="btnBranch" runat="server" Text="查询" OnClick="btnCheck_Click" />
        </div>
        <div style="margin-left: 100px; margin-top: 10px; width: 760px;">
            <asp:DataList ID="DataList1" runat="server" HorizontalAlign="Left" 
                RepeatColumns="1" Width="705px" DataKeyField="NewsId" 
                onitemcommand="DataList1_ItemCommand">
                <ItemStyle Height="120px" />
                <ItemTemplate>
                    <hr style="height: 2px; color: #ccc; width: 700px" />
                    <div style="text-align: left; margin: 0px 10px;">
                        标题：<asp:LinkButton ID="lbTitel" runat="server" CommandName="content" Text='<%# Bind("NewsTitle") %>'></asp:LinkButton>&nbsp;&nbsp;
                        新闻类型：<asp:Label ID="lbType" runat="server" Text='<%# Bind("NewsType.TypeName") %>'></asp:Label></div>
                    <div style="margin: 20px 15px; text-align: left;">
                        <asp:Label ID="lbContent" runat="server" CssClass="mlength" Text='<%# Bind("NewsContent") %>'
                            Height="30px"></asp:Label></div>
                    <div style="text-align: right; padding-right: 20px;">
                        发布人：<asp:Label ID="lbStfCode" runat="server" Text='<%# Bind("StfCode") %>'></asp:Label>
                        发布日期：<asp:Label ID="lbDate" runat="server" Text='<%# Bind("NewDate") %>'></asp:Label>
                        浏览人数：<asp:Label ID="lbHits" runat="server" Text='<%# Bind("Hits") %>'></asp:Label></div>
                </ItemTemplate>
            </asp:DataList>
        </div>
        <hr style="margin-left: 45px; height: 2px; color: #ccc; width: 700px" />
        <div style="text-align: right; margin-top: 5px; margin-left:500px;">
            <webdiyer:AspNetPager ID="AspNetPager1" runat="server" 
                CustomInfoHTML="当前第 %CurrentPageIndex% 页 共%PageCount%页" NextPageText="下一页" 
                PrevPageText="上一页" ShowCustomInfoSection="Left" ShowFirstLast="False" 
                ShowMoreButtons="False" ShowPageIndex="False" Width="320px" 
                AlwaysShow="True" onpagechanged="AspNetPager1_PageChanged">
            </webdiyer:AspNetPager>
            </div>
    </div>
</asp:Content>
